﻿@model IEnumerable<Test.Models.Base.Element>
@{
    ViewBag.Title = "Index";
}

<h2>Index</h2>

<ul>
    @foreach (var element in Model)
    {
        <li>
            @element.name
            @if (element.ElementLanguages.Any())
            {
                <ul>
                    @foreach (var elementLanguage in element.ElementLanguages)
                    {
                        <li>@elementLanguage.languageID @elementLanguage.name</li>
                    }
                </ul>
            }
        </li>
    }
</ul>